


#ifndef SAR_KERNEL_VM_HEADER_H
#define SAR_KERNEL_VM_HEADER_H

#include <kernel/kernel.h>
#include <kernel/handle/handle.h>

#include "limits.h"

/* browny points if you know the significance of 1870 */
#define VM_HEADER_MAGICNUMBER 0x1870

typedef struct HEADER {
	int MagicNumber;
	char FileName [VM_NAMELEN];	/* strictly for debugging */
	char AgentName [VM_NAMELEN];
	char HostName [VM_NAMELEN];	/* name of wait queue, etc */
	size TextSegmentSize;
	size DataSegmentSize;
	size CodeSegmentSize;
} vm_Header;


#define vm_header_read(_header, _h) handle_read (_h, _header, sizeof (vm_Header))
#define vm_header_write(_header, _h) handle_write (_h, _header, sizeof (vm_Header))



#endif
